<template>
  <div id="app" style="overflow: hidden;">
    <router-view />
    <el-backtop target="#app" :bottom="60"><i class="el-icon-top"></i></el-backtop>
  </div>
</template>

<script>
import { getConfigKey } from '@/api/sys/config';
import { configKey } from '@/enum/enums';
export default {
  name: 'App',
  data() {
    return {
    }
  },
  components: {
  },
  created() {
    document.getElementsByTagName('title')[0].innerText = this.$store.state.settings.systemName;
    this.getSystemConfig();
  },
  mounted() { },
  computed: {
  },
  methods: {
    getSystemConfig() {
      getConfigKey(configKey.barrageAssistantPort).then(res => {
        window.AudioConfig.websocketUrl += ":" + res.result.configValue;
      }).catch((e) => {
        console.error(e)
      });
    }
  }
};
</script>
<style lang="scss">
body {
  background-color: #eff2fd;
}
</style>
